<!DOCTYPE html>
<html lang="">
  <head>
    <meta charset="utf-8">
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <meta name="viewport" content="width=device-width,initial-scale=1.0">
    <link rel="icon" href="<%= BASE_URL %>favicon.ico">
    <title><%= htmlWebpackPlugin.options.title %></title>
  </head>
  <body>
    <noscript>
      <strong>We're sorry but <%= htmlWebpackPlugin.options.title %> doesn't work properly without JavaScript enabled. Please enable it to continue.</strong>
    </noscript>
    <div id="app"></div>
		<script src="/chat-mobile/sysconfig.js"></script>
    <!-- built files will be auto injected -->
		<script>
			(function() {
				// 设定基准宽度和对应的字体大小
				var baseWidth = 375; // 设计稿基准宽度，例如iPhone 6的视觉视口宽度
				var baseFontSize = 100; // 在基准宽度下的字体大小，例如100px

				// 计算函数，用于动态设置font-size
				var setRemUnit = function() {
					// 获取当前窗口宽度
					var width = document.documentElement.clientWidth;
					// 计算当前窗口宽度对应的目标font-size
					var fontSize = width / baseWidth * baseFontSize;
					// 设置html的font-size
					document.documentElement.style.fontSize = fontSize + 'px';
				};
				// 初始化时调用一次
				setRemUnit();
				// 监听窗口resize事件，当窗口大小发生变化时重新计算font-size
				window.addEventListener('resize', setRemUnit, false);
			})();
		</script>
  </body>
</html>
